raar.plugin
Class RAPluginManager

java.lang.Object
  extended by raar.plugin.RAPluginManager

public class RAPluginManager
extends java.lang.Object

The plug-in manager... well, manages plug-ins.


Field Summary
static java.lang.Class PLUGIN
          The plug-in superclass.
 
Constructor Summary
RAPluginManager(boolean all)
          Initialize using all the plugins in any subdirectory of this program.
RAPluginManager(java.lang.Class pluginClass)
          Initialize using all the plugins of the given class (or subclasses of it) in any subdirectory of this program.
RAPluginManager(java.lang.Class pluginClass, boolean all)
          Initialize using all the plugins of the given class (or subclasses of it) in any subdirectory of this program.
RAPluginManager(java.lang.Class pluginClass, java.io.File root, boolean all)
          Initialize using all the plugins of the given class (or subclasses of it) in any subdirectory of the root provided.
RAPluginManager(java.io.File root, boolean all)
          Initialize using all the plugins in any subdirectory of the root provided.
 
Method Summary
 java.lang.Object getObject(java.lang.String name)
          Get the object (not necessarily a plugin) with the given name, or null if it is not found.
 RAPlugin getPlugin(java.lang.String name)
          Get the plugin with the name given, or null if it is not found.
 java.lang.String[] getPluginNames()
          Return the plug-in names found.
static boolean isPluginEnabled(java.lang.Class plugin)
          Return whether the plugin class in question is enabled.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PLUGIN

public static final java.lang.Class PLUGIN
The plug-in superclass.

Constructor Detail

RAPluginManager

public RAPluginManager(boolean all)
Initialize using all the plugins in any subdirectory of this program.


RAPluginManager

public RAPluginManager(java.io.File root,
                       boolean all)
Initialize using all the plugins in any subdirectory of the root provided.


RAPluginManager

public RAPluginManager(java.lang.Class pluginClass)
Initialize using all the plugins of the given class (or subclasses of it) in any subdirectory of this program.


RAPluginManager

public RAPluginManager(java.lang.Class pluginClass,
                       boolean all)
Initialize using all the plugins of the given class (or subclasses of it) in any subdirectory of this program.


RAPluginManager

public RAPluginManager(java.lang.Class pluginClass,
                       java.io.File root,
                       boolean all)
Initialize using all the plugins of the given class (or subclasses of it) in any subdirectory of the root provided.

Method Detail

getPluginNames

public java.lang.String[] getPluginNames()
Return the plug-in names found.


getObject

public java.lang.Object getObject(java.lang.String name)
Get the object (not necessarily a plugin) with the given name, or null if it is not found.


getPlugin

public RAPlugin getPlugin(java.lang.String name)
Get the plugin with the name given, or null if it is not found.


isPluginEnabled

public static boolean isPluginEnabled(java.lang.Class plugin)
Return whether the plugin class in question is enabled.